shell script |
您所在的位置:网站首页 › windows call › shell script |
You are trying to run a Linux command at the Windows Command Prompt. On Linux the forward slash is a path separater. On Windows the backslash is a path separator and the forward slash generally indicates an argument. Therefore, Windows thinks you are trying to run a command called "." and parsing it the argument "/name.sh". The correct convention would be ".\name.sh". Additionally Windows will automatically search the current directory for your command so you could just type "name.sh". The next problem you will face is that Windows does not know what a sh script is, again this is a Linux thing. You could solve this by installing Cygwin if you really want or need to run a sh script. However, judging by one of your previous comments you could just as well rename the script to name.bat and delete the "#!/bin/sh" line. Now you have a Batch file which Windows should understand. You can read more about batch files here. |
CopyRight 2018-2019 办公设备维修网 版权所有 豫ICP备15022753号-3 |